let _request = option => uni.$http.create().setConfig({ ...option, showLoading: false }).request()

// 获取短信验证码
export const getSymCode = data => _request({ url: '/sms/verify-code', data, method: 'post' })

// 登陆
export const login = data => _request({ url: '/auth', data })

// 验证码登陆
export const symCodelogin = data => _request({ url: '/auth/sms-code', data })

// 验证码修改密码
export const symCodeByPassword = data => _request({ url: '/auth/password-by-sms-code', data, method: 'put' })

// 旧密码修改密码
export const oldPasswordEdit = data => _request({ url: '/auth/password', data, method: 'put' })

// 获取用户信息
export const getuserInfo = () => _request({ url: '/auth/user' })
//
export const getConfig = (data) => _request({ url: '/config' ,data})
//退出登录
export const loginOut = data => _request({ url: '/auth/login-out', data, method: 'put' })
